$OpenBSD: patch-libgfortran_Makefile_in,v 1.1.1.1 2013/04/08 08:20:25 pascal Exp $
--- libgfortran/Makefile.in.orig	Sat Oct  6 22:56:05 2012
+++ libgfortran/Makefile.in	Fri Oct 12 10:42:48 2012
@@ -500,9 +500,8 @@ LTLDFLAGS = $(shell $(SHELL) $(top_srcdir)/../libtool-
 toolexeclib_LTLIBRARIES = libgfortran.la
 toolexeclib_DATA = libgfortran.spec
 libgfortran_la_LINK = $(LINK) $(libgfortran_la_LDFLAGS)
-libgfortran_la_LDFLAGS = -version-info `grep -v '^\#' $(srcdir)/libtool-version` \
-	$(LTLDFLAGS) $(LIBQUADLIB) -lm $(extra_ldflags_libgfortran) \
-	$(version_arg) -Wc,-shared-libgcc
+include $(top_srcdir)/../libversions
+libgfortran_la_LDFLAGS = $(LIBgfortran_LTVERSION) $(LTLDFLAGS) $(LIBQUADLIB) -lm $(extra_ldflags_libgfortran) $(version_arg) -Wc,-shared-libgcc
 
 libgfortran_la_DEPENDENCIES = $(version_dep) libgfortran.spec $(LIBQUADLIB_DEP)
 myexeclib_LTLIBRARIES = libgfortranbegin.la
